<?xml version="1.0" encoding="UTF-8"?>
<jsp:root version="1.2" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:ui="http://www.sun.com/web/ui">
    <jsp:directive.page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"/>
    <f:view>
        <ui:page binding="#{disenoMemo.page1}" id="page1">
            <ui:html binding="#{disenoMemo.html1}" id="html1">
                <ui:head binding="#{disenoMemo.head1}" id="head1">
                    <ui:link binding="#{disenoMemo.link1}" id="link1" url="/resources/stylesheet.css"/>
                </ui:head>
                <ui:body binding="#{disenoMemo.body1}" focus="form1:txtFiltro" id="body1" style="-rave-layout: grid">
                    <ui:form binding="#{disenoMemo.form1}" id="form1">
                        <h:panelGrid binding="#{disenoMemo.gridPanel1}" columns="5" id="gridPanel1" style="left: 48px; top: 168px; position: absolute" width="240">
                            <ui:label binding="#{disenoMemo.label3}" id="label3" text="Subarea:"/>
                            <ui:dropDown binding="#{disenoMemo.dropDown1}" id="dropDown1" items="#{disenoMemo.dropDown1DefaultOptions.options}"
                                onChange="common_timeoutSubmitForm(this.form, 'gridPanel1:dropDown1');" style="width: 193px" valueChangeListener="#{disenoMemo.dropDown1_processValueChange}"/>
                            <ui:label binding="#{disenoMemo.label4}" for="txtFiltro" id="label4" text="Filtrar:"/>
                            <ui:textField binding="#{disenoMemo.txtFiltro}" id="txtFiltro"
                                onChange="common_timeoutSubmitForm(this.form, 'gridPanel1:txtFiltro');" style="width: 217px" valueChangeListener="#{disenoMemo.txtFiltro_processValueChange}"/>
                            <ui:button action="#{disenoMemo.button7_action}" binding="#{disenoMemo.button7}" id="button7" mini="true" primary="true"
                                style="width: 36px" text="Filtrar"/>
                        </h:panelGrid>
                        <ui:label binding="#{disenoMemo.label1}" id="label1"
                            style="color: rgb(108, 154, 154); font-size: 14px; left: 127px; top: 69px; position: absolute; width: 216px" text="Diseño de Memo"/>
                        <ui:table augmentTitle="false" binding="#{disenoMemo.table1}" clearSortButton="true" deselectMultipleButton="true" id="table1"
                            paginateButton="true" paginationControls="true" selectMultipleButton="true"
                            style="left: 48px; top: 208px; position: absolute; width: 573px" title="Tabla" width="573">
                            <script><![CDATA[
/* ----- Functions for Table Preferences Panel ----- */
/*
 * Toggle the table preferences panel open or closed
 */
function togglePreferencesPanel() {
  var table = document.getElementById("form1:table1");
  table.toggleTblePreferencesPanel();
}
/* ----- Functions for Filter Panel ----- */
/*
 * Return true if the filter menu has actually changed,
 * so the corresponding event should be allowed to continue.
 */
function filterMenuChanged() {
  var table = document.getElementById("form1:table1");
  return table.filterMenuChanged();
}
/*
 * Toggle the custom filter panel (if any) open or closed.
 */
function toggleFilterPanel() {
  var table = document.getElementById("form1:table1");
  return table.toggleTableFilterPanel();
}
/* ----- Functions for Table Actions ----- */
/*
 * Initialize all rows of the table when the state
 * of selected rows changes.
 */
function initAllRows1() {
  var table = document.getElementById("form1:table1");
  table.initAllRows();
}
/*
 * Set the selected state for the given row groups
 * displayed in the table.  This functionality requires
 * the 'selectId' of the tableColumn to be set.
 *
 * @param rowGroupId HTML element id of the tableRowGroup component
 * @param selected Flag indicating whether components should be selected
 */
function selectGroupRows(rowGroupId, selected) {
  var table = document.getElementById("form1:table1");
  table.selectGroupRows(rowGroupId, selected);
}
/*
 * Disable all table actions if no rows have been selected.
 */
function disableActions() {
  // Determine whether any rows are currently selected
  var table = document.getElementById("form1:table1");
  var disabled = (table.getAllSelectedRowsCount() > 0) ? false : true;
  // Set disabled state for top actions
  document.getElementById("form1:table1:tableActionsTop:deleteTop").setDisabled(disabled);
  // Set disabled state for bottom actions
  document.getElementById("form1:table1:tableActionsBottom:deleteBottom").setDisabled(disabled);
}]]></script>
                            <ui:tableRowGroup binding="#{disenoMemo.tableRowGroup1}" id="tableRowGroup1" selected="#{disenoMemo.selectedState}"
                                sourceData="#{disenoMemo.sct0001DataProvider}" sourceVar="currentRow">
                                <ui:tableColumn align="center" binding="#{disenoMemo.tableColumn23}" id="tableColumn23" onClick="setTimeout('initAllRows1()',0)"
                                    selectId="checkbox1" valign="middle" width="40">
                                    <ui:checkbox binding="#{disenoMemo.checkbox1}" id="checkbox1" selected="#{disenoMemo.selected}" selectedValue="#{disenoMemo.selectedValue}"/>
                                </ui:tableColumn>
                                <ui:tableColumn binding="#{disenoMemo.tableColumn2}" headerText="Codigo" id="tableColumn2" sort="SCT0001.CDGOVRBLE" width="144">
                                    <ui:staticText binding="#{disenoMemo.staticText2}" id="staticText2" text="#{currentRow.value['SCT0001.CDGOVRBLE']}"/>
                                </ui:tableColumn>
                                <ui:tableColumn binding="#{disenoMemo.tableColumn1}" headerText="Descripción" id="tableColumn1" sort="SCT0001.NMBREVRBLE" width="194">
                                    <ui:staticText binding="#{disenoMemo.staticText1}" id="staticText1" text="#{currentRow.value['SCT0001.NMBREVRBLE']}"/>
                                </ui:tableColumn>
                            </ui:tableRowGroup>
                            <f:facet name="title">
                                <ui:panelGroup binding="#{disenoMemo.groupPanel1}" id="groupPanel1" style="left: 432px; top: 192px">
                                    <ui:panelLayout binding="#{disenoMemo.layoutPanel1}" id="layoutPanel1" panelLayout="flow">
                                        <ui:label binding="#{disenoMemo.label2}" id="label2" text="Variables Disponibles"/>
                                        <ui:panelLayout binding="#{disenoMemo.layoutPanel2}" id="layoutPanel2" panelLayout="flow">
                                            <ui:textField binding="#{disenoMemo.textField1}" columns="30" id="textField1" style="width: 252px"/>
                                            <ui:button action="#{disenoMemo.button3_action}" binding="#{disenoMemo.button3}" id="button3" mini="true"
                                                primary="true" text="Insertar Titulo"/>
                                        </ui:panelLayout>
                                    </ui:panelLayout>
                                </ui:panelGroup>
                            </f:facet>
                            <f:facet name="actionsTop">
                                <ui:button action="#{disenoMemo.button2_action}" binding="#{disenoMemo.button2}" id="button2" mini="true" primary="true"
                                    style="left: 48px; top: 72px; width: 72px" text="Agregar &gt;"/>
                            </f:facet>
                        </ui:table>
                        <ui:alert binding="#{disenoMemo.alert1}" id="alert1" style="left: 174px; top: 96px; position: absolute; width: 551px"/>
                        <ui:table binding="#{disenoMemo.table2}" id="table2" style="left: 630px; top: 209px; position: absolute" title="Variables en Diseño" width="426">
                            <script><![CDATA[
/* ----- Functions for Table Preferences Panel ----- */
/*
 * Toggle the table preferences panel open or closed
 */
function togglePreferencesPanel() {
  var table = document.getElementById("form1:table2");
  table.toggleTblePreferencesPanel();
}
/* ----- Functions for Filter Panel ----- */
/*
 * Return true if the filter menu has actually changed,
 * so the corresponding event should be allowed to continue.
 */
function filterMenuChanged() {
  var table = document.getElementById("form1:table2");
  return table.filterMenuChanged();
}
/*
 * Toggle the custom filter panel (if any) open or closed.
 */
function toggleFilterPanel() {
  var table = document.getElementById("form1:table2");
  return table.toggleTableFilterPanel();
}
/* ----- Functions for Table Actions ----- */
/*
 * Initialize all rows of the table when the state
 * of selected rows changes.
 */
function initAllRows() {
  var table = document.getElementById("form1:table2");
  table.initAllRows();
}
/*
 * Set the selected state for the given row groups
 * displayed in the table.  This functionality requires
 * the 'selectId' of the tableColumn to be set.
 *
 * @param rowGroupId HTML element id of the tableRowGroup component
 * @param selected Flag indicating whether components should be selected
 */
function selectGroupRows(rowGroupId, selected) {
  var table = document.getElementById("form1:table2");
  table.selectGroupRows(rowGroupId, selected);
}
/*
 * Disable all table actions if no rows have been selected.
 */
function disableActions() {
  // Determine whether any rows are currently selected
  var table = document.getElementById("form1:table2");
  var disabled = (table.getAllSelectedRowsCount() > 0) ? false : true;
  // Set disabled state for top actions
  document.getElementById("form1:table2:tableActionsTop:deleteTop").setDisabled(disabled);
  // Set disabled state for bottom actions
  document.getElementById("form1:table2:tableActionsBottom:deleteBottom").setDisabled(disabled);
}]]></script>
                            <ui:tableRowGroup binding="#{disenoMemo.tableRowGroup2}" id="tableRowGroup2" rows="10" sourceData="#{SessionBean1.variables}" sourceVar="currentRow">
                                <ui:tableColumn binding="#{disenoMemo.tableColumn3}" headerText="Codigo" id="tableColumn3" sort="variable" style="#{disenoMemo.cstyle}">
                                    <ui:staticText binding="#{disenoMemo.staticText3}" id="staticText3" text="#{currentRow.value['variable']}"/>
                                </ui:tableColumn>
                                <ui:tableColumn binding="#{disenoMemo.tableColumn4}" headerText="Descripción" id="tableColumn4" sort="descripcion" style="#{disenoMemo.cstyle}">
                                    <ui:staticText binding="#{disenoMemo.staticText4}" id="staticText4" text="#{currentRow.value['descripcion']}"/>
                                </ui:tableColumn>
                                <ui:tableColumn binding="#{disenoMemo.tableColumn6}" headerText="Posición" id="tableColumn6" sort="posicion" style="#{disenoMemo.cstyle}">
                                    <ui:staticText binding="#{disenoMemo.staticText6}" id="staticText6" text="#{currentRow.value['posicion']}"/>
                                </ui:tableColumn>
                                <ui:tableColumn binding="#{disenoMemo.tableColumn7}" id="tableColumn7">
                                    <ui:button action="#{disenoMemo.button4_action}" binding="#{disenoMemo.button4}" id="button4" mini="true"
                                        onClick="if(!confirm('¿Seguro que desea quitar  esta Variable?')){return false;}" primary="true" text="Quitar"/>
                                </ui:tableColumn>
                                <ui:tableColumn binding="#{disenoMemo.tableColumn8}" id="tableColumn8">
                                    <ui:button action="#{disenoMemo.button5_action}" binding="#{disenoMemo.button5}" id="button5"
                                        imageURL="/resources/FlechaArriba.jpg" mini="true" primary="true" text="Subir"/>
                                </ui:tableColumn>
                                <ui:tableColumn binding="#{disenoMemo.tableColumn9}" id="tableColumn9">
                                    <ui:button action="#{disenoMemo.button6_action}" binding="#{disenoMemo.button6}" id="button6"
                                        imageURL="/resources/FlechaAbajo.jpg" mini="true" primary="true" text="Bajar"/>
                                </ui:tableColumn>
                            </ui:tableRowGroup>
                            <f:facet name="actionsTop">
                                <ui:button action="#{disenoMemo.btnGuardar_action}" binding="#{disenoMemo.btnGuardar}" id="btnGuardar" mini="true"
                                    primary="true" style="left: 600px; top: 72px" text="Guardar todo"/>
                            </f:facet>
                        </ui:table>
                        <ui:staticText binding="#{disenoMemo.stxtInfo}" id="stxtInfo" style="left: 24px; top: 72px; position: absolute" visible="false"/>
                        <ui:staticText binding="#{disenoMemo.stxtSwicth}" id="stxtSwicth" style="left: 24px; top: 48px; position: absolute" visible="false"/>
                        <ui:button action="#{disenoMemo.button1_action}" binding="#{disenoMemo.button1}" id="button1" immediate="true" mini="true"
                            primary="true" style="left: 48px; top: 118px; position: absolute; width: 71px" text="Cerrar"/>
                    </ui:form>
                </ui:body>
            </ui:html>
        </ui:page>
    </f:view>
</jsp:root>
